Repository navigation
pm: the low-risk arm lands an add-only ADR note as Tier S; any other ADR change stays H - #33975
Conversation
Claude-Session: https://claude.ai/code/session_01ADHkmRrk1KF2ZJk57PwVU9 Co-authored-by: Claude <noreply@anthropic.com>
…arm's add-only leg Claude-Session: https://claude.ai/code/session_01ADHkmRrk1KF2ZJk57PwVU9 Co-authored-by: Claude <noreply@anthropic.com>
…nly ADR leg Claude-Session: https://claude.ai/code/session_01ADHkmRrk1KF2ZJk57PwVU9 Co-authored-by: Claude <noreply@anthropic.com>
…re-scopes existing text, and the relay's fixtures follow the register Claude-Session: https://claude.ai/code/session_01ADHkmRrk1KF2ZJk57PwVU9 Co-authored-by: Claude <noreply@anthropic.com>
…finition and a disguised heading on an added line Claude-Session: https://claude.ai/code/session_01ADHkmRrk1KF2ZJk57PwVU9 Co-authored-by: Claude <noreply@anthropic.com>
…hyphens and character references Review round 3 (S8, N11-N13): addOnlyHeadingText strips default-ignorable characters and emphasis/code/strike markers, an added line carrying an HTML character reference or any default-ignorable character reads H, an opener heading needs a blank line above it, and the raw-HTML reason names the autolink. Two battery rows pin it; the battery floor is 39. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01ADHkmRrk1KF2ZJk57PwVU9
… unwritten ADR-0200 check:adr-anchors reads a fixture string as a live citation; the assertions only need some ADR id, so their meaning is unchanged. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01ADHkmRrk1KF2ZJk57PwVU9
Contract review round 4 (M1-M3, S1, S2, N1). An added non-blank line must be a plain ATX heading (plain text only) or plain prose, quoted or one list level, starting on a letter, digit or opening quote; no `<`, fence marker, tab or character reference anywhere. A status line is any line starting with a status word, Chinese included. A fence opened in a block quote ends with the quote, and a record carrying a list-borne or indented fence or a raw HTML block outside a fence takes no note. One row per probe string, both directions; the battery floor is 47. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01ADHkmRrk1KF2ZJk57PwVU9
…k-alike or letter-spaced ruled heading Contract review round 5 (S3, S4, N3). A non-blank added line directly above an existing setext heading reads H. Plain-heading letters are ASCII and Han only, and the ruled words are also read with spaces, punctuation and symbols squeezed out. A status word behind opening punctuation, or `… status:` anywhere on a line, is a status line. Three rows; the battery is pinned at 50. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01ADHkmRrk1KF2ZJk57PwVU9
…ed reading only refuses Contract review round 6 (S5, S6). 決策, 決定, 裁決 and 狀態 join both ruled patterns. Whether a record names a ruled heading at all is read by the word test alone, so a record whose only near match is `## Stat usage` takes no note. Two rows; the battery is pinned at 52. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01ADHkmRrk1KF2ZJk57PwVU9
|
domain:skills#1 · os-steve · session_01ADHkmPd7uRqHauEehGPr19 维护者速读
席位意见:建议批准。放权面只限对已有 ADR 的纯追加注释;任何改动既有文字、动决策或状态的提交仍是 Tier H,要您批。已知不拦的只有近义词(如「结论」)和故意错拼(如 席位核对 · ACCEPT · head
|
Keeps both sides in scripts/pm/check-governed-merges.mjs: the weekly audit card battery (#33814) and the ADR leg battery (#33539); the battery-roster floor is 40. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01ADHkmRrk1KF2ZJk57PwVU9
…es the low-risk arm main's mirror (#33948) reds a CODEOWNERS line on a Tier H row that carries the low-risk arm, and this branch puts the root `adr` row on the arm. The `/docs/adr/` line goes, `/ui/docs/adr/` stays, and the two comments naming the arm's rows follow. The quoted maintainer ruling stays verbatim; one line under it says it holds for every ADR change except an add-only note. The guard self-test's expected pattern lists and its one-approver fixture follow. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01ADHkmRrk1KF2ZJk57PwVU9
⛔ merge queue 构建失败 — 先分诊,再决定要不要重排队列构建 43745621751 红了。队列跑的是全量套件(PR 侧 CI 只跑 affected 子集), 分类: 失败的 job(日志抽取,best effort):
跨 PR 相同签名(24h,按失败测试文件聚合):
历史信号:
分诊清单:
Generated by Claude Code · merge-queue-triage workflow (#4859) |
… count a knock only from the fleet or a maintainer (objectstack-ai#33972) <!-- claude-projects-attribution: {"github_login":"os-steve"} --> _Requested by **Steve** · [project thread](https://claude.ai/code/project/chan_01FdL1XeUyvVNxLreh3F4Qi9?thread=cmsg_01FdL1XeUyvVNxLreh3F4Qi99Z1mjGd2zxMaR5rH5Z1Ada)_ Part of objectstack-ai#33789 Clause-②: no Metadata-protocol: none ## 维护者速读 - 改了什么:信箱 PR 开出后立刻锁定讨论(只有有写权限的账号能评论),旧信箱可用 `--lock N` 补锁;每次锁定后中继立即在信箱发一条自检评论,发不出就自动解锁并报错;读敲门的工具只认车队机器人与维护者账号,其余作者一律忽略、正文不读。 - 为什么改:仓库公开,任何 GitHub 用户都能在信箱下留一条伪造的敲门,白白进入座位会话、耗 token;本卡把「作者决定性质」从规则变成硬闸。 - 风险与回滚:锁定后车队机器人能否继续评论尚未实测,但每次锁定都由自检评论当场实测,失败即解锁,不会留下收不到敲门的信箱;中继只对带 pm:mailbox 的开放 PR 加锁或解锁。回滚 = revert 本 PR。 - 先看:`scripts/pm/mailbox-open.mjs` 的 `lockStroke` / `canaryStroke`;`scripts/pm/fleet-write/execute.mjs` 的 `mailboxLockPreflight`;`scripts/pm/record-recognisers.mjs` 的 `readMailboxComment`。 - 两分钟验证:`node scripts/pm/mailbox-open.mjs --repo objectstack-ai/objectstack --lock 32588 --dry-run`,应看到一个 `conversation_lock` 动作、不发任何请求。 - 需要你做的:受管面(`.claude/**`)PR,等 GOVERNED_APPROVERS 批准或席位达档复核;合并后由席位跑一次补锁所有已开信箱的中继扫射。 ## What changes Items 1 and 2 of the card land here; item 3 (the knock's session must match the named seat's post or mailbox opening) is left open, so this PR is `Part of` the card. What item 3 needs is under Acceptance notes. **Item 1 — the mailbox conversation is locked.** - `scripts/pm/fleet-write/ops.mjs`: two new relay rows. - `conversation_lock` takes `issue` alone and becomes ONE `PUT /repos/{o}/{r}/issues/{n}/lock` whose body is the table's one reason, `{ lock_reason: 'resolved' }` (`CONVERSATION_LOCK_REASON`). The caller cannot send a reason. - `conversation_unlock` takes `issue` alone and becomes ONE `DELETE` of the same path, with no body. It exists so that a lock is never one-way (see the canary below). - GitHub's server-to-server permission ledger (`github/docs` `src/github-apps/data/fpt-2022-11-28/server-to-server-permissions.json`, read 2026-11-15) lists the endpoint under `issues: write` and again under `pull_requests: write`. Both are literal grants on every stroke, so both rows spend `issues` and `.github/workflows/fleet-write.yml` is untouched. - `scripts/pm/fleet-write/execute.mjs` (review S2): the executor fences both rows on its own `GET` of the pull, the last read before the write, as it fences `mailbox_branch_delete`. It refuses with nothing sent unless the number is a pull request (an issue's number answers 404 on the pulls path), the pull is open, and it carries `pm:mailbox`. Each row lands only when the issue reads back with `locked` as asked. A write the platform refused whose conversation already reads that way is an idempotent landing; any other read is FAILED. - `scripts/pm/mailbox-open.mjs`: - The open gains step ⑤. Once ④ has read the new pull's number back, a second relay stroke sends `conversation_lock` on that number, and the pull is then read back `locked: true`. The lock cannot ride the `pr_create` stroke because an action names its pull by number, and the number exists only after the create answers. - A lock that fails leaves the mailbox open and unlocked. The open then exits non-zero and names the one re-send. - The canary (review S1). Once the pull reads back locked, a third relay stroke posts ONE comment on it: `MAILBOX_LOCK_CANARY` above the bare footer. The relay reads it back byte for byte. If the canary is refused, a fourth stroke sends `conversation_unlock`, the pull is read back unlocked, and the run exits 3 with a loud line: the lock was taken back, and no other mailbox is locked until the refusal is understood. If the unlock fails too, the line says the mailbox may stay locked and names the maintainer's "Unlock conversation". - Shape chosen: the canary is a fixed line, not a doorbell key (it opens with no `To:`). Its time stamp is the comment's own `created_at`, so the line carries no clock of its own. It rides its own stroke rather than the lock's, so a refusal is read as the canary's alone and the unlock is sent only for a lock that read back. - `--lock N` locks a mailbox opened before this change, with the same canary. It is the one spelling the post-merge sweep uses. It reads the pull first and refuses (exit 4) unless the pull is an open `pm:mailbox` PR, the same read `--close` makes. A pull that already reads `locked` costs zero writes and gets no canary. **Item 2 — a knock counts only from the fleet bot or a maintainer.** - `scripts/pm/record-recognisers.mjs`: `readMailboxComment(row)` fences the doorbell on the comment's author. A knock is read only when `user.login` is in `MAILBOX_KNOCK_AUTHORS`, which is `[RELAY_COMMENT_AUTHOR, ...GOVERNED_APPROVERS]`. It is judged by the queue guard's own predicate `recordAuthorTrusted`, and no login is typed here. Any other row reads exactly `{ state: 'ignored', reason: 'ignored: not a fleet or maintainer author' }`, and its body is never handed to the parser, so no line, key or seat of it can be echoed. - `mailboxEvents` lists ignored rows apart, as `ignored` with comment id, time and author only. They are never an event or a half-state, so check-half-states H72 does not list them (pinned end to end). - `--mailbox-keys` prints who may ring. - The relay's lock canary (the line alone above footer lines, one leading signature line allowed) reads `{ state: 'canary' }`. It is never an event and never a half-state, so H72 does not list it; `mailboxEvents` lists it apart as `canaries`. The same line from a maintainer, with a second line, or under a `To:` line reads as before. - Import edge: `check-governed-queue-guard.mjs` imports nothing of this graph at module scope, so the new static edge adds no cycle. Measured: the queue guard, post-stamped and recognisers self-tests pass, and `check-half-states.mjs` and `check-handover.mjs` load. **Skill text (governed, `.claude/**`)**: one line each. The pm-dispatch ratchet is paid by deletions in the same files: | File | Line added | Line deleted | Where the deleted rule still lives | Lines before → after | |:---|:---|:---|:---|:---| | `references/untrusted-text.md` | mailboxes are locked; a knock counts only from `objectstack-fleet[bot]` and `GOVERNED_APPROVERS` | the pointer that an adopted fork diff's internal PR waits for the maintainer's own approval | `references/external-contributions.md` ③ (lines 13–14, the rule itself) | 54 → 54 | | `references/seat-post-protocol.md` | knocks are judged on the author field like audit and claim comments (`readMailboxComment`) | the back-pointer sentence "见 seat-lifecycle.md 〈座位贴协议〉…" and the blank line under it | `references/seat-lifecycle.md:23` points to this file itself; other references name it by purpose | 88 → 87 | ## Tests Every number below was read at head 5fca76d, after the last commit (round 1, review S1 and S2). - `node scripts/pm/mailbox-open.mjs --self-test`: 103 cases in 11 batteries pass (was 90 in 10 before this PR). The battery "the lock" pins the one `conversation_lock` action the relay validator accepts, ⭐ the PUT the relay sends from it with the pull handed to the relay's fence, the open-mailbox read it runs behind, the `--lock` arguments, the re-send line and the open plan's step ⑤. Round 1 adds: ⭐ the canary is ONE relay comment, its first line `MAILBOX_LOCK_CANARY`, then the bare footer, accepted by the validator; ⛔ it is no doorbell key; ⭐ the unlock is one `conversation_unlock` and the DELETE the relay sends from it; the canary-failure line in both variants (taken back, or a maintainer's hand); and the `--lock` plan's canary step. The CLI battery has the `--lock` dry run with no gh or git on PATH. - `node scripts/pm/fleet-write/validate.mjs --self-test`: 435 cases across 23 batteries pass (was 428 across 22). The lock battery now covers both rows: closed keys (a caller-sent `lock_reason` refused), ⭐ the action shape each sends, issues write as a literal grant, and exactly two ops naming a lock, each request carrying the executor's fence. - `node scripts/pm/fleet-write/execute.mjs --self-test`: 423 cases across 31 batteries pass (was 415 across 30). New battery "the mailbox conversation lock": ⭐ lock and unlock each read the pull, send one write under the App token and read the issue back. ⛔ An issue's number, a closed pull, an unlabelled pull and an unread pull are each refused with nothing sent, for the lock and for the unlock. A 204 that does not read back as asked is FAILED. A refused write already in the asked state is idempotent. mailbox-open's lock, unlock and canary plans run through the executor. - `node scripts/pm/record-recognisers.mjs --self-test`: 400 cases pass (was 389); the doorbell battery floor is 44 → 55. ⭐ A fleet knock is read and a maintainer's knock is read. ⛔ A drive-by knock, spelled perfectly, reads only the ignored verdict, with the body marker absent from the result. Look-alike or missing authors are ignored, ignored rows are listed apart, the printout names who may ring, and H72 never lists a drive-by row. Round 1 adds: ⭐ the relay's canary reads `canary` (with or without a signature line); ⛔ the same line from a maintainer, with a second line or under `To:` reads as before, and an outsider's is ignored; `mailboxEvents` lists it apart; H72 does not list it. - `dispatch.mjs` (418), `check-governed-queue-guard.mjs` (530) and `post-stamped.mjs` (787) `--self-test` all pass unchanged, and `check-half-states.mjs` and `check-handover.mjs` load. **Forced test edits (named):** in the recognisers' doorbell battery, the fixture row author `DB_ROW` changed from `os-bill` to the relay's identity, because a knock arrives as the relay's comment. Under the new fence an `os-bill` row is ignored. The one case asserting `by === 'os-bill'` now asserts the relay's login. The H72 end-to-end case is otherwise unchanged and still lists the same three comments. In round 1, two pins changed because the rows changed: the lock's request shape now carries the `mailboxLock` fence descriptor (mailbox-open and validate), and validate's "no unlock row" case became "exactly two ops name a lock". In execute.mjs the row text for an idempotent landing is now taken from the confirming function when it names one (`idempotentText`); the branch delete's text is unchanged. ## Acceptance notes - The relay App commenting on a locked conversation is still not measured by hand, but no lock this code makes can leave a deaf mailbox: every lock is followed by the canary, and a refused canary takes the lock back. The sweep's first `--lock N` is that measurement. If its canary is refused, the sweep stops there. - The one-off sweep over every open mailbox is a relay run for the seat after merge (`mailbox-open.mjs --lock N` per open `pm:mailbox` PR). It is not run here. Each lock posts one canary, so each subscribed seat gets one PR-activity event, which its doorbell reader names a canary. - The relay fence is a label fence: it stops a mistyped or injected number, not a hostile seat, which could add the label first. - Item 3, what it needs: - A reader of the named seat's sessions, from its `pm:seat` post stub (session ID, `Successor-of:`) and its mailbox opening (the body footer's session URL). - A predicate over `readSignatureLine` that compares the knock's signature session with that set and reports "unverified seat signature". - A consumer that reads it, the receiving seat's knock read. That consumer is a board read, which this PR's pure reader does not do. - `seat-post-protocol.md` now stands at 87 lines under a ceiling of 88 (headroom 1). The pin lives in `scripts/pm/check-skill-line-ratchet.mjs`, outside this card's file surface, so review nit N2 is not taken here. - `execute.mjs` joined the file surface in round 1 (claim amendment 6896718263). PR objectstack-ai#33975 touches its self-test fixture too; a later lander resolves the conflict. ## Verification <details><summary>Local gates at 5fca76d (round 1)</summary> `node scripts/pm/dispatch-gates.mjs --commands --repo objectstack-ai/objectstack` derived 47 commands at 5fca76d (46 at 5039a67, plus `pnpm check:pm-write-pace` for `execute.mjs`); each was run and its exit code captured before any pipe: ```text 0 10s node scripts/check-closing-keyword-parity.mjs 0 3s node scripts/check-closing-keyword-parity.mjs --self-test 0 191s node scripts/check-comment-mask-corpus.mjs 0 0s node scripts/check-declaration-mirrors.mjs 0 1s node scripts/check-declaration-mirrors.mjs --self-test 0 1s node scripts/check-self-test-wired.mjs 0 6s node scripts/check-self-test-wired.mjs --self-test 0 139s node scripts/check-self-test-workflow-commands.mjs 0 5s node scripts/check-self-test-workflow-commands.mjs --self-test 0 2s node scripts/check-whole-set-label-write.mjs 0 0s node scripts/check-whole-set-label-write.mjs --self-test 0 0s node scripts/ci/plan-test-core-shards.mjs --self-test 0 30s node scripts/pm/bare-root-worklist.mjs --self-test 0 5s node scripts/pm/check-harness-current.mjs --self-test 0 10s pnpm --filter @objectstack/lint run check:doc-formula-expressions 0 3s pnpm check:agent-test-spelling 0 1s pnpm check:bash32-floor 0 3s pnpm check:ci-filter-parity 0 15s pnpm check:cli-command-ids 0 33s pnpm check:cross-package-test-inputs 0 6s pnpm check:doc-authoring 0 3s pnpm check:driver-memory-census 0 33s pnpm check:entry-guard 0 1s pnpm check:gitlink-declared 0 4s pnpm check:nul-bytes 0 3s pnpm check:parse-guard 0 1s pnpm check:pm-close-cards 0 369s pnpm check:pm-dispatch-gates 0 5s pnpm check:pm-fleet-write-dispatch 0 4s pnpm check:pm-fleet-write-execute 0 1s pnpm check:pm-fleet-write-validate 0 7s pnpm check:pm-governed-merges 0 1s pnpm check:pm-issue-create 0 1s pnpm check:pm-issue-transfer 0 1s pnpm check:pm-label-write 0 2s pnpm check:pm-post-stamped 0 5s pnpm check:pm-record-recognisers 0 1s pnpm check:pm-skill-id-lint 0 0s pnpm check:pm-skill-ratchet 0 4s pnpm check:pm-write-pace 0 2s pnpm check:pnpm-filter-targets 0 5s pnpm check:pnpm-flag-spellings 0 3s pnpm check:ratchet-remedy-authority 0 23s pnpm check:refd-timer-probe 0 7s pnpm check:scripts-symbol-anchors 0 1s pnpm check:skill-frame-sync 0 5s pnpm check:watch-hint-literal ``` `--ran` reconciliation: `✓ dispatch-gates --ran: 47 derived famil(ies) accounted for — 47 run, 0 NOT-MEASURED (a DERIVED zero — all 47 recorded an exit code and none of them is 3).` Round 0 (5039a67): 46 of 46 exit 0. Its first commit 8e20953 had `check:pm-dispatch-gates` red (1 of 2205): the census pins `scripts/pm/record-recognisers.mjs:77 self-test-reads` by line, and a header line had moved the marker to 78. That was fixed by folding the header entry into the line above; round 1 adds no line above 77. `check:doc-formula-expressions` exited 3 (prerequisite: `@objectstack/formula` and `@objectstack/lint` unbuilt) until those two were built under the lock (`VERDICT command-exit 0`). </details> --- _Generated by [Claude Code](https://claude.ai/code/session_01ADHkmPAZjatd5E4EVfAi5F)_ <!-- signed: domain:skills#1 · os-steve · session_01ADHkmPAZjatd5E4EVfAi5F --> --------- Co-authored-by: Claude <noreply@anthropic.com>
…d on a seat signature on any line (objectstack-ai#34037) <!-- claude-projects-attribution: {"github_login":"os-steve"} --> _Requested by **Steve** · [project thread](https://claude.ai/code/project/chan_01FdL1XeUyvVNxLreh3F4Qi9?thread=cmsg_01FdL1XeUyvVNxLreh3F4Qi9N1Z1u2rEtm3MkQHMEhxcoQ)_ Part of objectstack-ai#33768 Clause-②: no Metadata-protocol: none ## 维护者速读 - 改了什么:给中继出队(dequeue)补一条自测——出队后第二次读 PR 失败时不算确认、整对重读;两处函数注释改成"读两次";插队的"携带批准"评论只要任一行带席位签名就拒收(原来只看首行)。 - 为什么改:这是 PR objectstack-ai#33732 复审留下的三条小尾巴(E2、E3、D3),注释与文件头不一致,签名藏在第二行就能绕过"席位评论不算维护者批准"。 - 风险与回滚:只动 `scripts/pm/fleet-write/` 两个脚本,不发布;D3 只会让更多评论被拒、不会放宽;回滚 = revert 本 PR。 - 先看:`scripts/pm/fleet-write/ops.mjs` 的 `enqueueFrontSizeLift`(逐行读签名那一行);`execute.mjs` 自测里新增的 "a SECOND pull read that fails" 一行。 - 两分钟验证:`node scripts/pm/fleet-write/execute.mjs --self-test`,应看到 "424 cases pass across 31 batteries"。 - 需要你做的:无,席位落地。 ## What changes Three items of the objectstack-ai#33768 checklist (review follow-ups of PR objectstack-ai#33732). The rest stay open on the card: the `fleet-write.yml` comment and the AGENTS.md sentence (Tier H, a later governed batch), N1/E1 (measured at the first live stroke), D2, D4 and N2 (each needs a budget or a ruling). - **E2** (`execute.mjs` self-test). The rows near the dequeue read-back pinned a failed FIRST pull read (`pullLate`: 502, ok) and a merge that shows only on the second read (`mergedLate`), but no failed SECOND read. New row: pull reads ok, 502, ok, ok. The 502 confirms nothing, so the queue is read again at the interval and the pair starts over. It lands at three polls (clock `3 * DEQUEUE_POLL_MS`), with 5 pull GETs and 4 GraphQL calls. The pr_dequeue battery pin goes 28 → 29, with a roster comment. - **E3** (jsdocs). `dequeueAction` now says the pull's own GET reads it open and unmerged TWICE, one `pollMs` apart, and that a failed second read starts the pair over. `dequeuePullAfter` now says it judges ONE of the two reads and the executor lands only when both are `ok`. Both match the file headers. - **D3** (optional hardening, taken: it stays inside `scripts/pm/fleet-write/**`). `enqueueFrontSizeLift` runs the passed-in signature reader on every line of the `approval_comment`, not only the first non-empty one. A seat signature on any line refuses the carry, and the reading says "holds the seat signature". The row "⭐ CARRIED, the other way: … signature line further down … still carries it" flips to "⛔ CARRIED, refused on ANY line", which also checks that the reading names the seat. The SIZE lift battery stays at 12 cases; its name ("holding a seat signature on any line"), the `ops.mjs` header paragraph and the `execute.mjs` header sentence now say any line. The reader stays passed in, so `ops.mjs` still imports no guard. No changeset: the diff is `scripts/pm/**` only and publishes nothing (`skip-changeset`). ## Tests At head 1c433b2: - `node scripts/pm/fleet-write/execute.mjs --self-test`: 424 cases pass across 31 batteries (423 at base c3c0c30). - Forced test edit: the D3 row "signature line further down still carries it" is flipped to a refusal, as the card asks. <details><summary>Ablations (both red on exactly the new pin, restored, `git diff HEAD` empty)</summary> Run with `node scripts/ablation-replace.mjs` (the anchor must hit, restore is checked on disk) after the fix was committed. - E2: the second read's `if (after.ok) return` changed to `if (after.ok || after.pending) return`. Result: `✗ a SECOND pull read that fails (ok, 502) … — got [0,3000,3,3], want [0,9000,5,4]`, 1 of 424 failed. - D3: the line scan changed back to `signatureOf(c.body)` (first line only). Result: `✗ ⛔ CARRIED, refused on ANY line … — got [[0,1,200],false], want [[5,0,"not sent"],true]`, 1 of 424 failed. </details> ## Acceptance notes - Concurrency: PR objectstack-ai#33975 (self-test fixtures near L2909–2962) and PR objectstack-ai#34022 (removes the mailbox lock rows and battery, so the battery floor goes 31 → 30) also touch `execute.mjs`. Their hunks do not overlap these. Whichever lands later rebases; the floor and the per-battery pins here move independently of objectstack-ai#34022's. ## Verification <details><summary>Derived gates (37 of 37 exit 0, at head 1c433b2)</summary> `node scripts/pm/dispatch-gates.mjs --commands --repo objectstack-ai/objectstack` listed 37 commands; each one exited 0: check-closing-keyword-parity (+ self-test), check-comment-mask-corpus, check-declaration-mirrors (+ self-test), check-self-test-wired (+ self-test), check-self-test-workflow-commands (+ self-test), check-whole-set-label-write (+ self-test), plan-test-core-shards self-test, bare-root-worklist self-test, and the pnpm checks agent-test-spelling, bash32-floor, ci-filter-parity, cli-command-ids, cross-package-test-inputs, driver-memory-census, entry-guard, gitlink-declared, nul-bytes, parse-guard, pm-close-cards, pm-dispatch-gates, pm-fleet-write-dispatch, pm-fleet-write-execute, pm-fleet-write-validate, pm-issue-transfer, pm-post-stamped, pm-record-recognisers, pm-write-pace, pnpm-filter-targets, pnpm-flag-spellings, refd-timer-probe, scripts-symbol-anchors, watch-hint-literal. `--ran` reconciliation: `✓ dispatch-gates --ran: 37 derived famil(ies) accounted for — 37 run, 0 NOT-MEASURED (a DERIVED zero — all 37 recorded an exit code and none of them is 3).` </details> 🤖 Generated with [Claude Code](https://claude.com/claude-code) https://claude.ai/code/session_01ADHkmPoZhhhS5uc7UQqwZ7 --- _Generated by [Claude Code](https://claude.ai/code/session_01ADHkmPoZhhhS5uc7UQqwZ7)_ Co-authored-by: Claude <noreply@anthropic.com>
…/pm module, transitively (objectstack-ai#34080) <!-- claude-projects-attribution: {"github_login":"os-steve"} --> _Requested by **Steve** · [project thread](https://claude.ai/code/project/chan_01FdL1XeUyvVNxLreh3F4Qi9?thread=cmsg_01FdL1XeUyvVNxLreh3F4Qi9MG4BPhsDcJCksmNwyRu6xu)_ Fixes objectstack-ai#33848 Clause-②: no Metadata-protocol: none ## 维护者速读 - 改了什么:派发工具 `dispatch-gates.mjs` 新增「import 图」匹配键:改动落在 `scripts/pm/**` 下的某个模块时,所有直接或间接 import(含动态 import、再导出)它的门禁脚本所属的门禁族都会被派生出来,输出里打印从门禁脚本到该模块的整条 import 链。 - 为什么改:PR objectstack-ai#33804 第一版只改了 `check-governed-queue-guard.mjs` 和 `check-governed-merges.mjs`,`--commands` 派生 35 条、漏了 `check:pm-fleet-write-execute`(它的脚本 import 了被改的函数),开发者「35 条全绿」而 CI 红。现在同一组文件派生 62 条,含 fleet-write 的执行器、校验器和派发器。 - 风险与回滚:只改 `scripts/pm/**` 下一个工具脚本和它的自测,不发布任何包。新键排在所有旧键之后,旧匹配的键与来源标签一字不变,只会多派、不会少派;代价是改大多数 pm 模块会多派约 40 多个门禁族(pm 工具互相 import 成一个大环,这是实测的真实影响面)。回滚即还原本 PR。 - 先看:`scripts/pm/dispatch-gates.mjs` 的 `loadEdgeTargets`(读 import 边,含动态 import 的兜底)与 `coveringKey` 末尾的新分支;自测文件里 `The import-graph key (objectstack-ai#33848)` 一节和改过的两条旧用例。 - 两分钟验证:`node scripts/pm/dispatch-gates.mjs --commands scripts/pm/check-governed-queue-guard.mjs scripts/pm/check-governed-merges.mjs | grep fleet-write`,预期三行 `pnpm check:pm-fleet-write-{dispatch,execute,validate}`(修复前零行)。 - 需要你做的:无,席位落地(非受管面)。 ## What changes `dispatch-gates --commands` named a gate when a changed path was the gate's own script, a CI trigger, a job filter, a literal the gate spells, or a file it reads. It never named a gate because its script **imports** the changed module: `coveringKey`'s docblock refused that key (objectstack-ai#13126) on precision, because the shared heads under `scripts/` (`invoked-as.mjs` and four others) are imported by most families. The pm tools are the opposite shape, and the measured miss is the card's: on PR objectstack-ai#33804's first head the derivation named 35 gates, not `check:pm-fleet-write-execute`, whose script imports a changed function and whose self-test then went red in CI. A new key, consulted **last** in `coveringKey`, answers a changed path under `IMPORT_GRAPH_KEY_ROOT` (`scripts/pm/`): a family matches when the path is in the transitive load closure of its gate files. Read from the module's side that is the reverse import graph over `scripts/pm/**`, at any depth. The row prints the chain, e.g. `import graph scripts/pm/fleet-write/execute.mjs -> scripts/pm/check-governed-queue-guard.mjs`. Outside `scripts/pm/` the objectstack-ai#13126 refusal stands unchanged (a self-test row pins that). | Piece | What it does | |:--|:--| | `loadEdgeTargets(path, source)` | One file's first-party load edges: static `import … from`, `export … from` (a re-export loads its target), the side-effect form, a dynamic `import()` of a string literal or of `new URL(literal, import.meta.url)`. Comments are masked; a keyword inside a string or template literal is fixture text, not a load. Self-test bodies are **not** masked: a `--self-test` run loads them. | | Unreadable dynamic `import()` | The argument is a variable, a property or a computed URL. It is not dropped: every code-position module literal in that file becomes an edge, whether relative or spelled from the repo root under `scripts/` (toward deriving more). Both shapes are live: a loader seam (`load = (specifier) => import(specifier)`) with its relative specifiers in a constant (`ARM_READER_SOURCE`), and a root-spelled roster loaded in process (`fleet-write/dispatch.mjs`'s self-test imports each sender through `pathToFileURL(join(REPO_ROOT, sender))`; `check-dispatch-gates.mjs` loads its engine through `import(resolve(ROOT, TOOL))`). The root spelling also takes fixture rows and text reads written the same way (five modules `check-governed-merges.mjs` names as data); that over-derives, which is this key's direction. | | `importGraphReach(files, edgesOf)` | Breadth-first forward closure from a family's gate files, recording each module's first importer, so the printed chain is a shortest one. Walks self-test families and gate files too: the key claims what RUNNING the family loads, never what it watches, so neither population narrowing applies. | | `discoverFamilies` | Computes `entry.importReach` for every family, one scan per file per discovery. | | `derivationInputs` | Adds every reached module, since its edges decide what the key names. | Resolution is the existing first-party rule: relative specifiers only, inside `scripts/`, outside `node_modules`, the target must exist. A bare specifier is an installed package. Measured on this tree (b8685e5), and printed by a self-test row on every run rather than recorded in prose: the key reaches 28 pm modules over 1195 (family, module) pairs, and the most-reached module, `clause2-line.mjs`, names 53 families. The pm tools close into one large cycle (the governed register, the half-state patrol, the queue guard and the dispatch-gates engine load one another), so an edit to most pm modules names forty-odd families. That is the measured size of what such an edit can break. Time, measured on a quiet container, two cold runs each: a discovery took 16.6 s and 14.8 s before the key (base e71ecc1) and 17.2 s and 17.0 s with it (6f34ab1); a whole `--commands` run over one pm path took 36.0 s and 37.0 s before and 38.0 s and 35.7 s after. The review's 48.7 s was the same run on a loaded box. The stale "~14 s cold" in `derivationInputs`' docblock now carries these readings. ## Tests Full battery (`node scripts/pm/dispatch-gates.mjs --self-test`, both tiers) on b8685e5: **2530 cases pass** (fast 2215 + slow 315), lock `VERDICT command-exit 0`. Round 1: 2528 passed on 80bc14b and on e6452d3. New rows, all in the fast tier: - Fixture graph (in memory, so the shapes cannot rot with the tree): the reader takes the static import, the re-export, the side-effect form, a literal `import()` inside a self-test body and a `new URL` import; it refuses an import spelled in a template literal or a comment and a bare package; an unread `import()` widens to every module literal in the file, relative or root-spelled; CONTROL: the same two literals in a file with no unread `import()` are no edges. - ⭐ Transitive row: in the fixture, `b.mjs` reached only through `gate.mjs -> a.mjs -> b.mjs` names the family, and the row prints that chain. - Scope row: a module outside `scripts/pm/` reached by import is still answered by no key. - ⭐ Root-spelled roster row (live tree, review M1): `scripts/pm/issue-create.mjs`, which no file under `scripts/` imports statically and which the dispatcher's self-test loads by root path, derives `check:pm-fleet-write-dispatch` through the import graph. - Price row: prints the modules the key reaches, the (family, module) pairs and the most-reached module, asserting only that the key reaches anything. - ⭐ Replay row (live tree): PR objectstack-ai#33804's first file list places `check:pm-fleet-write-execute` as matched via `import graph scripts/pm/fleet-write/execute.mjs -> …`, rendered `pnpm check:pm-fleet-write-execute`; and `check:pm-fleet-write-validate` and `check:pm-fleet-write-dispatch` match too. Forced edits to existing rows (both are about the key order this PR extends): 1. **The objectstack-ai#13126 witness** (`the witness holds — bare-root-worklist --self-test imports THIS file, and no key names that family…`) asserted the refusal's one known missing lead. That module is under `scripts/pm/`, so the new key names it; the row now asserts the edge exists AND the key that names it is the import-graph key (`the witness is paid back — …`). The other five refusal pins (novel class, worst head, concentration, the deferred-pair pins) are unchanged and green. 2. **Read-key additivity** (`every read edge earns a key, and none is re-attributed …`) stripped `entry.reads` and compared against the keys left. The new key now sits after the read key, so with the reads stripped it answered those targets and the row reported 7 false re-attributions (`program text read by …` -> `import graph …`). The row now strips `entry.importReach` too, so it compares the read key against the keys consulted BEFORE it, which is its claim. <details><summary>Ablation: the new branch in coveringKey disabled on disk, exactly the four key rows red, restored (head e6452d3)</summary> Through `node scripts/ablation-replace.mjs` (anchor hits 1 -> 0 on disk, blob `7d65b7fe4962` -> `09197c9f6da0`), the fast tier under `os-verify-lock.sh`; restore: blob == HEAD (`7d65b7fe4962`) and `git diff HEAD` empty. ```text mutation: the import-graph branch's condition prefixed with `false &&` -> VERDICT command-exit 1, 4 of 2213 failed: the witness is paid back — bare-root-worklist --self-test imports THIS file, and the import-graph key names that family for a card editing it the transitive row: a module reached only through an importer of an importer names the family, and the row prints the chain from the gate file the replay row: PR objectstack-ai#33804's first file list derives check:pm-fleet-write-execute, through the import graph …and the validator and the dispatcher, the other two fleet-write families the card names (the edge-reader rows and the scope row stay green, as they must: they do not read the key) ``` </details> <details><summary>Ablation, round 2 (review M1): the root-spelled half of the fallback disabled on disk, exactly two rows red, restored (head b8685e5)</summary> Through `node scripts/ablation-replace.mjs` (anchor hits 1 -> 0, blob `8e00e6752a69` -> `fcd7324b7a64`), the fast tier under `os-verify-lock.sh`; restore: blob == HEAD (`8e00e6752a69`) and `git diff HEAD` empty. ```text mutation: a root-spelled literal in a file with an unreadable import() is skipped instead of admitted -> VERDICT command-exit 1, 2 of 2215 failed: an import() whose argument is not a literal widens toward MORE: every module literal in the file is an edge, relative or spelled from the repo root a sender the dispatcher loads by a root-spelled path derives check:pm-fleet-write-dispatch, through the import graph ``` </details> ## Acceptance notes - Additive by construction: the key is the last one `coveringKey` consults, so every (family, path) pair an earlier key answered keeps its key and label; the 2,520 rows that existed before stay green except the two forced edits above. - Price, stated rather than hidden: a card editing most `scripts/pm/` modules now derives about 62 commands where it derived about 30 (this PR's own card: 62). Every added row prints its import chain, so a reader can check why it is there. - Not covered by this key: the import closure of a script a gate only SPAWNS as a child (`node scripts/pm/x.mjs`) is not walked; the existing run and read keys answer the spawned file itself where they apply. carrier: objectstack-ai#34084. - The related evidence the delta names (`check:adr-anchors` reddened by a fixture string on PR objectstack-ai#33975) is a different mechanism: that family declares five hints (`docs/adr`, `scripts/adr-anchors`, its own script and two `CHANGELOG.md` files) and no whole-tree marker, while its scan reads the whole tree's text. Its population is under-declared; not fixed here. carrier: objectstack-ai#34086. - Serial: objectstack-ai#34002 (dotAll in `triggerPatternRegex`, same file) is held and not folded in. ## Verification Local subset on b8685e5 (round 2; main e71ecc1 merged in): `node scripts/pm/dispatch-gates.mjs --commands --repo objectstack-ai/objectstack` derived 62 commands; 61 exit 0 and one exit 3 (each exit captured before any pipe). `--ran` with every line annotated `:: exit N`: **62 derived, 61 run, 1 NOT-MEASURED (derived from the recorded exit 3), 0 UNRUN**. `pnpm check:i18n-coverage` is derived only through the import graph (its self-test imports the engine): its self-test half passed, its scan half refused with exit 3 because the CLI build closure is not built here; declared to CI. No package touched, so no build closure and no package test is owed. <details><summary>The 62 commands and their exit codes</summary> ```text node scripts/check-closing-keyword-parity.mjs :: exit 0 node scripts/check-closing-keyword-parity.mjs --self-test :: exit 0 node scripts/check-comment-mask-corpus.mjs :: exit 0 node scripts/check-declaration-mirrors.mjs :: exit 0 node scripts/check-declaration-mirrors.mjs --self-test :: exit 0 node scripts/check-issue-citations.mjs :: exit 0 node scripts/check-self-test-wired.mjs :: exit 0 node scripts/check-self-test-wired.mjs --self-test :: exit 0 node scripts/check-self-test-workflow-commands.mjs :: exit 0 node scripts/check-self-test-workflow-commands.mjs --self-test :: exit 0 node scripts/check-skills-token-ratchet.mjs :: exit 0 node scripts/check-skills-token-ratchet.mjs --self-test :: exit 0 node scripts/check-whole-set-label-write.mjs :: exit 0 node scripts/check-whole-set-label-write.mjs --self-test :: exit 0 node scripts/ci/plan-test-core-shards.mjs --self-test :: exit 0 node scripts/ci/scheduled-full-run-card.mjs --self-test :: exit 0 node scripts/ci/scheduled-full-run.mjs --self-test :: exit 0 node scripts/ci/snapshot-next.mjs --self-test :: exit 0 node scripts/pm/bare-root-worklist.mjs --self-test :: exit 0 node scripts/pm/board-snapshot.mjs --self-test :: exit 0 node scripts/pm/check-governed-queue-guard.mjs --self-test :: exit 0 node scripts/pm/sweep-closed-cards.mjs --self-test :: exit 0 pnpm check:agent-test-spelling :: exit 0 pnpm check:bash32-floor :: exit 0 pnpm check:ci-filter-parity :: exit 0 pnpm check:cli-command-ids :: exit 0 pnpm check:closing-target-claim :: exit 0 pnpm check:commit-card-trailers :: exit 0 pnpm check:cross-package-test-inputs :: exit 0 pnpm check:declared-population-live :: exit 0 pnpm check:driver-memory-census :: exit 0 pnpm check:entry-guard :: exit 0 pnpm check:gitlink-declared :: exit 0 pnpm check:i18n-coverage :: exit 3 pnpm check:issue-citations :: exit 0 pnpm check:nul-bytes :: exit 0 pnpm check:parse-guard :: exit 0 pnpm check:partof-closing-keyword :: exit 0 pnpm check:pm-board-snapshot :: exit 0 pnpm check:pm-close-cards :: exit 0 pnpm check:pm-dispatch-gates :: exit 0 pnpm check:pm-expected-skips :: exit 0 pnpm check:pm-fleet-token :: exit 0 pnpm check:pm-fleet-write-dispatch :: exit 0 pnpm check:pm-fleet-write-execute :: exit 0 pnpm check:pm-fleet-write-validate :: exit 0 pnpm check:pm-governed-merges :: exit 0 pnpm check:pm-governed-prose :: exit 0 pnpm check:pm-half-states :: exit 0 pnpm check:pm-issue-create :: exit 0 pnpm check:pm-issue-transfer :: exit 0 pnpm check:pm-label-write :: exit 0 pnpm check:pm-post-stamped :: exit 0 pnpm check:pm-prior-rulings :: exit 0 pnpm check:pm-record-recognisers :: exit 0 pnpm check:pnpm-filter-targets :: exit 0 pnpm check:pnpm-flag-spellings :: exit 0 pnpm check:ratchet-remedy-authority :: exit 0 pnpm check:refd-timer-probe :: exit 0 pnpm check:scripts-symbol-anchors :: exit 0 pnpm check:single-claim-paths :: exit 0 pnpm check:watch-hint-literal :: exit 0 ``` </details> --- _Generated by [Claude Code](https://claude.ai/code/session_01ADHkmRtrFmEsp5pAjTBpMT)_ <!-- signed: domain:skills#1 · os-steve · session_01ADHkmPd7uRqHauEehGPr19 --> --------- Co-authored-by: Claude <noreply@anthropic.com>
…dispatch-gates derives it for every card (objectstack-ai#34114) <!-- claude-projects-attribution: {"github_login":"os-steve"} --> _Requested by **Steve** · [project thread](https://claude.ai/code/project/chan_01FdL1XeUyvVNxLreh3F4Qi9?thread=cmsg_01FdL1XeUyvVNxLreh3F4Qi92Vt19B5bTPa1d6K7Nf4xkL)_ Fixes objectstack-ai#34086 Clause-②: no Metadata-protocol: none ## 维护者速读 - 改了什么:门禁 `check:adr-anchors` 在源码里声明「我读整棵树」(dispatch-gates 现有的 whole-tree-population 标记),派发工具 `dispatch-gates` 同步认得 `git grep` 这种全树读法;从此每张卡的 `--commands` 都会派出这个门禁。 - 为什么改:这个门禁用 `git grep` 扫全仓所有文本文件里的 `ADR-NNNN` 引用,却只声明了 4 个路径;改它们之外的文件时派发清单不点它,开发者本地全绿、CI 才红(PR objectstack-ai#33975 就是一个 `scripts/pm/` 脚本里的测试字符串触发的)。 - 风险与回滚:只改三个工具脚本,不发布任何包。每张卡多派一条命令,实测约 11 秒。dispatch-gates 只在识别清单末尾追加一条,原有三条及其下标不动。回滚即还原本 PR。 - 先看:`scripts/check-adr-anchors.mjs` 的 `collectCitations` 上方新标记行与自测 `live-scan-population-is-declared`;`scripts/pm/dispatch-gates.mjs` 的 `REPO_ROOT_WALK_SPELLINGS` 第四条。 - 两分钟验证:`node scripts/pm/dispatch-gates.mjs --commands scripts/pm/check-governed-merges.mjs | grep adr-anchors`,预期一行 `pnpm check:adr-anchors`(修复前零行)。 - 需要你做的:无,席位落地(非受管面)。 ## What changes `check:adr-anchors`' third check (objectstack-ai#6634) collects citations with `git grep --untracked -IonE …` and no pathspec, so it reads every tracked and every untracked-not-ignored text file. Its source spelled only four path literals (`docs/adr`, its own script and the two release-owned `CHANGELOG.md` files on its excuse list), so `dispatch-gates` placed the family by those alone and scored it `silent` for any other file. Measured on main f81e4b6: 10,237 tracked files cite an ADR, 10,078 of them outside those literals; `--commands scripts/pm/check-governed-merges.mjs` derived 33 commands and not this one. **Route: declare, don't narrow.** The whole-tree read is the point of the check (a citation nobody resolves rots wherever it is written), so the scan stays as it is. `wide-population` was also rejected: it keeps a family out of `--commands`, which is the opposite of the acceptance and of "a miss fails toward deriving more". The existing `whole-tree-population` marker (the channel `check:nul-bytes` and seven other families use) is the fit. No new declaration grammar. | File | Change | |:--|:--| | `scripts/check-adr-anchors.mjs` | The `// dispatch-gates: whole-tree-population -- …` line above `collectCitations`, with a note on why the scan is not narrowed. A live self-test case, `live-scan-population-is-declared`, holds the marker to the scan in both directions: a scan reading more than one top-level root needs the marker, and a marker over a one-root scan is red too. The live battery's floor moves 21 → 22 for that case. | | `scripts/pm/dispatch-gates.mjs` | `REPO_ROOT_WALK_SPELLINGS` gains limb D, `a \`git grep\` search of the tracked corpus`, appended after limbs 0–2 (unchanged). Without it the marker was REFUSED ("its own source carries no recognised repo-root walk … EXTEND REPO_ROOT_WALK_SPELLINGS"). The regex is held to the execFile shape (`'git'` then an argv array holding `'grep'`), so the system `spawnSync('grep', …)` over one named file in `check-skill-compatibility-version.mjs` does not match. Out of the card's file surface: declared to the seat before the edit and approved, with the claim's surface amended. | | `scripts/pm/dispatch-gates.self-test.mjs` | Two fixture cases beside limbs A–C: limb D reads the execFile `git grep`; the system grep is not a walk. | ## Tests - `node scripts/check-adr-anchors.mjs --self-test`: 134 assertions pass, floor included. - `pnpm check:pm-dispatch-gates` (fast tier): 2207 cases pass, 335 s. - Acceptance, before and after: on f81e4b6 `node scripts/pm/dispatch-gates.mjs --commands scripts/pm/check-governed-merges.mjs` printed 33 lines, 0 naming `check:adr-anchors`; on a6876cc it prints 34, including `pnpm check:adr-anchors`, placed under "Always runs (declared population)" with the marker's reason. The always-runs block grows 8 → 9 families. - No forced edits to existing test rows. ## Acceptance notes - Price: every card's `--commands` now carries `pnpm check:adr-anchors` (self-test plus scan, about 11 s measured here). - Serial: PR objectstack-ai#34080 (in the merge queue) and card objectstack-ai#34084 also edit `scripts/pm/dispatch-gates.mjs`, in other regions; whichever lands second resolves. - The claim's acceptance line asks for `check-governed-merges.mjs --pr` and the tier; the reading is in the os-dev-report on the card. ## Verification Local gates on a6876cc (main f81e4b6 is the base): `node scripts/pm/dispatch-gates.mjs --commands --repo objectstack-ai/objectstack` derived 33 commands; all 33 exit 0. `--ran`: **33 derived, 33 run, 0 NOT-MEASURED, 0 UNRUN**. No package touched, so no build closure and no package test is owed; no changeset (`skip-changeset`). <details><summary>The 33 commands and their exit codes</summary> ```text node scripts/check-closing-keyword-parity.mjs :: exit 0 node scripts/check-closing-keyword-parity.mjs --self-test :: exit 0 node scripts/check-comment-mask-corpus.mjs :: exit 0 node scripts/check-declaration-mirrors.mjs :: exit 0 node scripts/check-declaration-mirrors.mjs --self-test :: exit 0 node scripts/check-self-test-wired.mjs :: exit 0 node scripts/check-self-test-wired.mjs --self-test :: exit 0 node scripts/check-self-test-workflow-commands.mjs :: exit 0 node scripts/check-self-test-workflow-commands.mjs --self-test :: exit 0 node scripts/check-whole-set-label-write.mjs :: exit 0 node scripts/check-whole-set-label-write.mjs --self-test :: exit 0 node scripts/ci/plan-test-core-shards.mjs --self-test :: exit 0 node scripts/pm/bare-root-worklist.mjs --self-test :: exit 0 pnpm check:adr-anchors :: exit 0 pnpm check:agent-test-spelling :: exit 0 pnpm check:bash32-floor :: exit 0 pnpm check:ci-filter-parity :: exit 0 pnpm check:cli-command-ids :: exit 0 pnpm check:cross-package-test-inputs :: exit 0 pnpm check:declared-population-live :: exit 0 pnpm check:driver-memory-census :: exit 0 pnpm check:entry-guard :: exit 0 pnpm check:gitlink-declared :: exit 0 pnpm check:nul-bytes :: exit 0 pnpm check:parse-guard :: exit 0 pnpm check:pm-dispatch-gates :: exit 0 pnpm check:pm-governed-merges :: exit 0 pnpm check:pnpm-filter-targets :: exit 0 pnpm check:pnpm-flag-spellings :: exit 0 pnpm check:ratchet-remedy-authority :: exit 0 pnpm check:refd-timer-probe :: exit 0 pnpm check:scripts-symbol-anchors :: exit 0 pnpm check:watch-hint-literal :: exit 0 ``` </details> --- _Generated by [Claude Code](https://claude.ai/code/session_01ADHkmT9YphoBfbtPDaBJrs)_ --------- Co-authored-by: Claude <noreply@anthropic.com>
…14 names the arm's rows (objectstack-ai#34115) Fixes objectstack-ai#34107 <!-- claude-projects-attribution: {"github_login":"os-steve"} --> _Requested by **Steve** · [project thread](https://claude.ai/code/project/chan_01FdL1XeUyvVNxLreh3F4Qi9?thread=cmsg_01FdL1XeUyvVNxLreh3F4Qi9DhBTDykFH6f9bchWYkPpus)_ Clause-②: no Metadata-protocol: none ## 维护者速读 - 改了什么:补上 objectstack-ai#33975 第 5 轮合同复审的两处修复:AGENTS.md PD14 的 CODEOWNERS 一句改为“除低风险臂的行外”(根 ADR 树已随 objectstack-ai#33975 离开 CODEOWNERS);合并后巡检的“有利答案”只给 `diff-tree --raw` 状态读,ADR 补丁读失败时如实记“未测到”。 - 为什么改:objectstack-ai#33975 已在队列中合并,这两处来不及推上去(卡 objectstack-ai#34107);PD14 那句原文在 objectstack-ai#33975 之后已不成立,巡检会把一次没读到的补丁当成测到的 Tier H。 - 风险与回滚:只改一句规则文和一个纯函数的判定条件,回滚即 revert。删掉 `/docs/adr/` 的 CODEOWNERS 行后,根 ADR 的 PR 若以 ready 状态打开(或手动转 ready),GitHub 不再自动发 code-owner 审查请求;对“只增注释以外”的 ADR 改动,裁决改由队列守卫(无 GOVERNED_APPROVERS 批准即拒)和中继逐 PR 请求两位批准人来守住。 - 先看:`scripts/pm/check-governed-merges.mjs` 的 `favourableArmGitRead`,以及 AGENTS.md 第 306 行。 - 两分钟验证:`node scripts/pm/check-governed-merges.mjs --self-test`,看 `objectstack-ai#33539-S7-…` 一行。 - 需要你做的:本 PR 动 AGENTS.md(Tier H),保持 draft,请 GOVERNED_APPROVERS 审批。 ## What changes - **AGENTS.md Prime Directive 14** (contract review 6898480793, M4): "CODEOWNERS routes every Tier H surface but the low-risk catalogs" becomes "… but the low-risk arm's rows". Since objectstack-ai#33975 the root ADR tree is an arm row with no CODEOWNERS line, and an ADR tree is not a catalog. One word swap, same line, 118 bytes; AGENTS.md stays at 1050 lines. - **`favourableArmGitRead`** (`scripts/pm/check-governed-merges.mjs`, S7): it now answers only the `diff-tree --raw` status read (argv carries `--raw`, not `-p`). The ADR leg's `diff-tree -p` patch read has no favourable answer, so in the post-merge sweep an ADR landing whose patch read alone fails stays NOT MEASURED (sweep incomplete) instead of reading Tier H on a status listing handed back as a patch. The queue, the relay and `--pr` were never affected: there an unread ADR diff already reads H. - One self-test row pins it in the sweep battery: `⛔ objectstack-ai#33539-S7-an-ADR-landing-whose-patch-read-alone-fails-stays-NOT-MEASURED-only-the-raw-read-has-a-favourable-answer`. The existing N-a row that called `favourableArmGitRead(['diff-tree', LANDED], …)` now passes `--raw` (a forced test edit: the bare argv no longer has a favourable answer). ## Why PR objectstack-ai#33975 merged from the queue at `b60484d4` before these round-5 fixes could be pushed. Card objectstack-ai#34107 carries them. ## Verification - `node scripts/pm/check-governed-merges.mjs --self-test`: 863 assertions, exit 0. - Ablation: answering the patch read too (the pre-fix condition) reds exactly the new S7 row; restored, green. - `pnpm check:pm-skill-ratchet` green; AGENTS.md 1050 lines. - `node scripts/pm/dispatch-gates.mjs --commands` on this head: 38 derived, 38 run, all exit 0, reconciled with `--ran`; `check:adr-anchors` and the 10 importer self-tests exit 0. ### Not carried - The objectstack-ai#33975 round-5 nit N9 (rewrapping and wording the CODEOWNERS header note) is not in this card's file surface, so `.github/CODEOWNERS` is untouched here. ## Human Minimum - [x] 1. Schemas start as Zod; `packages/spec` holds no runtime logic. (not touched) - [x] 2. Every name I added uses the casing for its kind. - [ ] 3. No formatter ran; `pnpm lint` passes. (no formatter ran; `pnpm lint` not run here — no package source changed; CI's ESLint leg reads it) - [x] 4. One issue, one branch off an up-to-date `main`, one pull request. - [x] 5. A change that publishes carries a changeset, and both declaration lines are filled in here and in the changeset. (nothing publishes: `skip-changeset`) - [x] 6. `packages/spec` touched: its generated artifacts are regenerated and committed. (not touched) - [x] 7. No hand edits to `content/docs/references/`, `packages/*/CHANGELOG.md` or `content/docs/releases/`. - [x] 8. Title, body and comments are in English. (except the required 维护者速读 block) - [x] The *Before Submitting* list in CONTRIBUTING.md is done. 🤖 Generated with [Claude Code](https://claude.com/claude-code) https://claude.ai/code/session_01ADHkmRrk1KF2ZJk57PwVU9 <!-- signed: domain:skills#1 · os-steve · session_01ADHkmRrk1KF2ZJk57PwVU9 --> Co-authored-by: Claude <noreply@anthropic.com>
Fixes #33539
Requested by Steve · project thread
Clause-②: no
Metadata-protocol: none
维护者速读
docs/adr/**,只放行“只增注释”:每个 hunk 只加不删、不加 Status 行、不在 Decision/Status 节下加行、不新建/改名/删除 ADR 文件。本 PR 同时删掉.github/CODEOWNERS的/docs/adr/行(main 的 chore(governance): drop the skills CODEOWNERS rows; the mirror exempts low-risk arm rows #33948 规定带臂的行不得有 CODEOWNERS 行;/ui/docs/adr/保留),头注释里逐字引的裁决「adr 只能由维护者自己确认,人工合并,ai 不得擅自合并。」原样保留,其下加一行:该裁决因此收窄到“只增注释以外”的 ADR 改动。adr行回到普通 Tier H。 删掉/docs/adr/的 CODEOWNERS 行后,根 ADR 的 PR 若以 ready 状态打开(或手动转 ready),GitHub 不再自动发 code-owner 审查请求;对“只增注释以外”的 ADR 改动,裁决改由队列守卫(无 GOVERNED_APPROVERS 批准即拒)和中继逐 PR 请求两位批准人来守住。scripts/pm/check-governed-merges.mjs的addOnlyNoteReasons与lowRiskArmVerdict改动,再看队列守卫catalogFilesOf。node scripts/pm/check-governed-merges.mjs --self-test与node scripts/pm/check-governed-queue-guard.mjs --self-test,看 ADR 两组电池。What changes
scripts/pm/check-governed-merges.mjs): theadrrow (docs/adr/**, Tier H) gainslowRisk: { repos: ['objectstack'], addOnly: true }. It is one more path family under the same low-risk arm (pm: land low-risk governed PRs on the seat review (Tier S arm for skills wording and docs), per the 2026-11-14 delegation ruling #33501 ruling), not a new arm: the arm's conditions stay as they are (no contract, no security label or name, no fork, same-head PASS record).addOnlyNoteReasons), from a full-context diff of merge base to head (addOnlyDiffArgv:--no-renames --no-ext-diff --no-textconv --unified=1000000, literal pathspec). A modifieddocs/adr/NNNN-*.mdreads S only when:#…######, one space, plain text of ASCII letters and digits, Han characters and plain punctuation: no other script, emphasis, code, link, HTML,#or\), or plain prose at column 0, optionally>-quoted and behind one list marker, starting on a letter, digit, opening quote or bracket. No<(raw HTML, autolinks), fence marker, tab or character reference anywhere. Anything else reads H;Status (date): …,(Status): …,Superseded by,Deprecated:,**状态**:…), or carrying… status:/…状态:anywhere;D e c i s i o n,S.t.a.t.u.s) — a reading used only to refuse, never to decide that a record names a ruled heading, and no added line sits directly above an existing setext heading (it would join that heading's text);Decision,Status,Decided,Ruling,Resolution, 决策/决定/裁决/状态 and the traditional 決策/決定/裁決/狀態), and no added heading names one;scripts/pm/check-governed-queue-guard.mjs):catalogFilesOfreads each queued ADR file's commit diff with the same argv (diff-tree -p -m --first-parent), so the merge_group leg passes such a PR on the same rule and its PASS record carries over as before.--pr/ post-merge sweep: all read throughpullCatalogReading, which now attaches the ADR patch; no second reader, andscripts/pm/fleet-write/execute.mjslogic is untouched..github/CODEOWNERS(claim amendment 6898158057): the/docs/adr/line is deleted, because main's mirror (chore(governance): drop the skills CODEOWNERS rows; the mirror exempts low-risk arm rows #33948, ruling record 6891850019) reds a CODEOWNERS line on a Tier H row carrying the low-risk arm;/ui/docs/adr/keeps its line. The verbatim maintainer ruling in the header stays, with one line under it: it holds for every ADR change except an add-only note. The guard self-test's expected pattern lists and its one-approver fixture (now on/ui/docs/adr/) follow.lowRiskArmVerdict). Line counts unchanged (AGENTS.md 1050, pm-dispatch 320).Why
Card #33539: a seat should be able to land an add-only ADR note on the low-risk arm's Tier S path, while any change to an ADR's ruling or status stays Tier H.
Verification
check-governed-merges, battery "⚖️ pm: let a seat land an add-only ADR note under the low-risk Tier H ruling (docs/adr/** stays Tier H until then) #33539 …", 52 cases, pinned at 52):pullCatalogReadingpath.## Stat usagenames no ruled heading); the ADR battery is pinned at 52. Probe over the 155 shipped records: an appended plain note reads S on 149; the 6 others name no decision or status heading, so they read H.docs/adr/**+packages/core/**diff reads the arm (timeline GET), still plans Tier H and requests both approvers.node scripts/pm/dispatch-gates.mjs --commandson the final head: every listed command run and reconciled with--ran; plus the importer self-tests.## **Notes**heading now read H (they read S before the allowlist).Forced test edits (named)
scripts/pm/fleet-write/execute.mjs(self-test only, surface added by the seat's claim amendment): the Tier H fixturetierHFilesand thetwoPagesfixture useddocs/adr/**, which now reads the arm. Both move todocs/NORTH-STAR.md(still Tier H, no arm); the three expected strings follow. One new row pins the ADR + core behaviour above.check-governed-mergesexisting arm tests: the arm-rows test now expectsadr,skills-catalog,ui-skills-catalog, withaddOnlyonly onadr; thelowRiskRowHittest follows.SELF_TEST_BATTERY_FLOOR39 → 40 after the merge of main (main's review follow-ups of PR #33766 #33814 took 38 → 39; the ADR battery itself pinned at 52), guard 31 → 32.Notes for the reviewer
.github/workflows/**" became "本仓 workflows" (the glob survives at the register line, L184), and "(技能独占)" became "(该面独占)".<, fences, tables, nested lists, headings with markup) reads H; records with no ruled heading always read H.ui/docs/adr/**is not on the arm and stays H.Human Minimum
packages/specholds no runtime logic. (not touched)pnpm lintpasses. (no formatter ran;pnpm lintwas not run here, since no package source changed: the derived gate list and the script self-tests ran instead)main, one pull request.skip-changeset)packages/spectouched: its generated artifacts are regenerated and committed. (not touched)content/docs/references/,packages/*/CHANGELOG.mdorcontent/docs/releases/.🤖 Generated with Claude Code
https://claude.ai/code/session_01ADHkmRrk1KF2ZJk57PwVU9